package org.blackcat.dao.redis;

import org.springframework.beans.factory.annotation.Value;
import org.springframework.stereotype.Component;

/**
 * Created by Duo Duo on 2017/1/4.
 */
@Component
public class RedisConfig {
    @Value("${redis.ip}")
    private  String ip;
    @Value("${redis.auth}")
    private  String auth;
    @Value("${redis.port}")
    private  int port;
    @Value("${redis.maxActive}")
    private  int maxActive;
    @Value("${redis.maxIdle}")
    private  int maxIdle;
    @Value("${redis.maxWaitMillis}")
    private  int maxWaitMillis;
    @Value("${redis.timeout}")
    private  int timeout;
    @Value("${redis.testOnBorrow}")
    private  boolean testOnBorrow;

    public String getIp() {
        return ip;
    }

    public void setIp(String ip) {
        this.ip = ip;
    }

    public String getAuth() {
        return auth;
    }

    public void setAuth(String auth) {
        this.auth = auth;
    }

    public int getPort() {
        return port;
    }

    public void setPort(int port) {
        this.port = port;
    }

    public int getMaxActive() {
        return maxActive;
    }

    public void setMaxActive(int maxActive) {
        this.maxActive = maxActive;
    }

    public int getMaxIdle() {
        return maxIdle;
    }

    public void setMaxIdle(int maxIdle) {
        this.maxIdle = maxIdle;
    }

    public int getMaxWaitMillis() {
        return maxWaitMillis;
    }

    public void setMaxWaitMillis(int maxWaitMillis) {
        this.maxWaitMillis = maxWaitMillis;
    }

    public int getTimeout() {
        return timeout;
    }

    public void setTimeout(int timeout) {
        this.timeout = timeout;
    }

    public boolean isTestOnBorrow() {
        return testOnBorrow;
    }

    public void setTestOnBorrow(boolean testOnBorrow) {
        this.testOnBorrow = testOnBorrow;
    }
}
